package com.my.elasticsearchspringdemo.entity;

import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;

import java.io.Serializable;

/**
 * @Description
 * @Author Godzilla
 * @Date 2019/7/6
 * @Version V1.0.0
 * @Update 更新说明
 */
@Document(indexName = "users",type="user")
public class User implements Serializable{

    @Field
    private Long id;

    @Field
    private String name;

    @Field
    private String hobby;

    @Field
    private String birthday;


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getHobby() {
        return hobby;
    }

    public void setHobby(String hobby) {
        this.hobby = hobby;
    }

    public String getBirthday() {
        return birthday;
    }

    public void setBirthday(String birthday) {
        this.birthday = birthday;
    }
}
